package testPackage;

public class Student {
    private int money = 500; // 私有钱属性
    private int score = 80;

    public int getMoney() {
        return money;
    }

    // 获取分数
    public int getScore() {
        return score;
    }

    // 设置分数
    public void setScore(int score) {
        if (score >= 0) {
            this.score = score;
        }
    }
}
